package com.hq.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

@Controller
@RequestMapping("/sys")
public class SystemController {

    //修改医生个人信息
    @RequestMapping("updateDoctor")
    public String updateDoctor(){
        return "doctorPage";
    }
    //修改个人信息
    @RequestMapping("/updatePage")
    public String updatePage() {
        return "info";
    }

    //修改密码（pwd）
    @RequestMapping("/updatePwd")
    public String updatePwd() {
        return "adminPass";
    }

    //预约
    @RequestMapping("/goPage")
    public String goPage() {
        return "page";
    }

    //体检人员
    @RequestMapping("/goLogin")
    public String goLogin() {
        return "login";
    }

    @RequestMapping("/goList")
    public String goList() {
        return "list";
    }

    //返回登录界面（pwd）
    @RequestMapping("/returnLogin")
    public String returnLogin() {
        return "login";
    }
    //登录(pwd)
    @RequestMapping("/adminIndex")
    public String adminIndex() {
        return "adminIndex";
    }

    //登录(pwd)
    @RequestMapping("/doctorIndex")
    public String doctorIndex() {
        return "doctorIndex";
    }

    //登录(pwd)
    @RequestMapping("/massIndex")
    public String massIndex() {
        return "massIndex";
    }

    //注册(pwd)
    @RequestMapping("/signIn")
    public String signIn() {
        return "sign-in";
    }

    //管理员页面体检人员
    @RequestMapping("/goAdmin")
    public String goAdmin() {
        return "admin";
    }

    //回馈体检信息（cyc）
    //查看所有医护人员信息
    @RequestMapping("/goAdminDoctor")
    public String adminDoctor() {
        return "adminDoctor";
    }

    //管理员页面体检人员
    @RequestMapping("/goReply")
    public String goReply() {
        return "reply";
    }

    //管理员查看医生下面的预约信息(pwd)
    @RequestMapping("/goLookAppoint")
    public String goLookAppoint(HttpServletRequest request) {
        System.out.println(request.getParameter("name"));
        return "lookAppoint";
    }

    //返回医生首页（cyc）
    @RequestMapping("/goDoctorIndex")
    public String goDoctorIndex() {
        return "doctorIndex";
    }

    //去添加医生（pwd）
    @RequestMapping("/goAddDoctor")
    public String goAddDoctor() {
        return "adminAddDoctor";
    }
}
